<?php
App::uses('Folder', 'Utility');
App::uses('File', 'Utility');
class HomesController extends AppController {
	public $name = 'Homes';
	
	function index(){
		$dir = new Folder(WWW_ROOT);
		$file = new File($dir->pwd() . DS . 'APIs.txt');
		//$fileName = $file->name() ;
		$contents = $file->read () ;
		// $file->write('I am overwriting the contents of this file');
		// $file->append('I am adding to the bottom of this file.');
		// $file->delete(); // I am deleting this file
		$file->close(); // Be sure to close the file when you're done
		$this->set('apis',$contents);
		//debug($fileName);
		//exit();
	}
	
	
}